/**
 * Copyright 1993-2012 NVIDIA Corporation.  All rights reserved.
 *
 * Please refer to the NVIDIA end user license agreement (EULA) associated
 * with this source code for terms and conditions that govern your use of
 * this software. Any use, reproduction, disclosure, or distribution of
 * this software and related documentation outside the terms of the EULA
 * is strictly prohibited.
 */
/*#include <string.h>

#include <stdio.h>
#include <stdlib.h>
#include <getopt.h>
#include "Utils.cuh"
#include "Tcdefs.h"
#include "Crypto.cuh"
#include "Core.cuh"


int main(void) {
	int i=0;
	int header_length;

	unsigned char salt[PKCS5_SALT_SIZE];

	int block_size = 2;
	unsigned char encryptedHeader[512]={0};
	unsigned char blockPwd [256];
	int blockPwd_init[block_size];
	int blockPwd_length[block_size];

	//int keyDerivationFunction;

	//read the volume
	header_length = file_readHeader("/home/gazpacho/tfm/prueba_truecrypt", encryptedHeader, 0, 0);

	printf("header_length: %d\n",header_length);

	for (i=0;i<512;i++){
		printf("[%d]: %d\n",i,encryptedHeader[i]);
	}

	memcpy (salt, encryptedHeader + HEADER_SALT_OFFSET, PKCS5_SALT_SIZE);
	for (i=0;i<PKCS5_SALT_SIZE;i++){
				printf("[%d]: %x\n",i,salt[i]);
			}
	blockPwd_init[0]=0;
	blockPwd_length[0]=11;

	for(i=0;i<blockPwd_length[0];i++){
		blockPwd[i]=i+'1';
	}
	blockPwd[9]='0';
	blockPwd[10]='\0';

	blockPwd[11]='1';
	blockPwd[12]='2';
	blockPwd[13]='3';
	blockPwd[14]='4';
	blockPwd[15]='\0';

	blockPwd_init[1]=11;
	blockPwd_length[1]=5;


	for(i=0;i<blockPwd_length[0];i++){
		printf("%c",blockPwd[i]);
	}



	int CORE_blocksize=1024;

	cuda_Init (CORE_blocksize, salt,encryptedHeader) ;
	short int *result;
	result=(short int*)malloc(CORE_blocksize*sizeof(short int));

	int CORE_keyDerivationFunction;
	CORE_keyDerivationFunction=1;//RIPEMD160;

	//derive_key_ripemd160 ( blockPwd+blockPwd_init[0], blockPwd_length[0], salt, PKCS5_SALT_SIZE, 2000, headerKey, cpu_GetMaxPkcs5OutSize ());
	cuda_Core_dictionary ( 0,block_size, blockPwd, blockPwd_init, blockPwd_length, result, CORE_keyDerivationFunction);
	//cuda_Core_dictionary ( int encryptionAlgorithm, int bsize, unsigned char *blockPwd, int *blockPwd_init, int *blockPwd_length, short int *result, int keyDerivationFunction) {

	free(result);
	cuda_Free () ;

	return 0;
}*/
